<table class="layui-table text-center" lay-size="sm">
    <thead>
        <tr>
            <th>图片</th>
            <th><div class="text-left">账号</div></th>
            <th>SKU</th>
            <th><div class="text-left">商品名</div></th>
            <th>平台PDF</th>
            <th>生成PDF</th>
            <th>自定义文字</th>
            <th>是否生成</th>
            <th>状态</th>
            <th>排序</th>
            <th>备注</th>
            <th>操作</th>
        </tr>
    </thead>
    <tbody>
        {volist name="list" id="item"}
            <tr>
                <td>{if !empty($item.image_url)}<img src="{$item.image_url}"/>{/if}</td>
                <td class="text-left">{$item.account.username}</td>
                <td class="copy-text">{$item.sku}</td>
                <td class="text-left">{$item.name_ch}</td>
                <td>{if !empty($item.path_pdf)}<a href="{$item.path_pdf}" target="_blank"><i class="fa fa-file-pdf-o"></i></a> {/if}</td>
                <td>{if !empty($item.merge_path_pdf)}<a href="{$item.merge_path_pdf}" target="_blank"><i class="fa fa-file-pdf-o"></i></a> {/if}</td>
                <td>{$item.merge_text}</td>
                <td>
                    <span class="{$item.is_merge?'text-yellow':'text-muted'}"><i class="fa fa-circle"></i> {$item.is_merge?'是':'否'}</span>
                </td>
                <td>
                    {php}$status = $item['status'];{/php}
                    <a href="{:url('save',['barcode_id'=>$item['barcode_id'], 'status'=>abs(1-$status)])}" class="ajax-get" msg="0" style="font-size: 16px;">
                        {$status?'<i class="fa fa-unlock"></i>':'<i class="fa fa-lock text-red"></i>'}</a>
                </td>
                <td>{$item.sort}</td>
                <td class="text-left">{$item.remark}</td>
                <td>
                    <a item="{$item.merge_path_pdf}" class="pdf-do-print layui-btn layui-btn-xs layui-btn-normal">打印</a>
                    <a href="{:url('add',['barcode_id'=>$item['barcode_id']])}" class="layui-btn layui-btn-xs layui-btn-warm ajax-form" title="平台条码">编辑</a>
                    <a href="{:url('merge',['barcode_id'=>$item['barcode_id']])}" title="生成" confirm="1" class="layui-btn layui-btn-xs ajax-get">生成</a>
                    <a href="{:url('delete',['ids'=>$item['barcode_id']])}" title="删除" confirm="1" class="layui-btn layui-btn-xs layui-btn-danger ajax-get">删除</a>
                </td>
            </tr>
        {/volist}
        {empty name="list"}
        <tr>
            <td colspan="12">没有数据</td>
        </tr>
        {/empty}
    </tbody>
</table>
<div class="page">
    {$page|raw}
</div>